<template>
  <div>
    <p>请选择你喜欢的专栏</p>
    <div v-for="(item,index) in likes" :key="index">
      <input type="checkbox" v-model="secLikes" :value="item"/><span >{{item}}</span>
    </div>
    <li v-for="(item,index) in secLikes" :key="index">{{item}}</li>
  </div>
</template>

<script>
export default {
  name: 'LikeApp',

  data() {
    return {
      // 数据在这里
      likes:["科幻", "喜剧", "动漫", "冒险", "科技", "军事", "娱乐", "奇闻"],
      // 选择的专栏
      secLikes:[]
    };
  },

  mounted() {
    
  },

  methods: {
    
  },
};
</script>

<style lang="less" scoped>
div {
  display:inline;
  float: left;
}
</style>